﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Baidu.API.Entity {
    public class TransResult{
        public string from;
        public string to;
        public Trans_result[] trans_result;

        /// <summary>
        /// 重载 ToString。 返回翻译成功的字符串
        /// </summary>
        /// <returns></returns>
        public override string ToString(){
            var sb = new StringBuilder();
            foreach (var item in trans_result){
                sb.AppendFormat("{0}: {1}\r\n", item.src, item.dst);
            }
            return sb.ToString();
        }
    }

    public class Trans_result {
        public string src;
        public string dst;
    }
}
